import 'author_basic_info.dart';

// 单条评论信息
class CommentItemInfo {
  final int comment_id;
  final AuthorBasicInfo authorBasicInfo;
  final String createTime;
  final int like_num;
  final String content;
  final bool isLike;
  final String parentCommontRealname;

  CommentItemInfo({
    this.comment_id,
    this.authorBasicInfo,
    this.createTime,
    this.like_num,
    this.content,
    this.isLike,
    this.parentCommontRealname,
  });

  factory CommentItemInfo.init(Map<String, dynamic> json) {
    return CommentItemInfo(
      comment_id: json['commentId'],
      authorBasicInfo: AuthorBasicInfo.init(json['author']),
      createTime: json['createTime'],
      like_num: json['like_num'],
      content: json['content'],
      isLike: json['isLike'],
      parentCommontRealname: json['parentCommentRealname'],
    );
  }
}
